package com.pro.framework.api.database;

import lombok.AllArgsConstructor;
import lombok.Data;

@Data
@AllArgsConstructor
public class FieldDTO {
    private String relationCode;
    private String fieldName;

    public String toFieldSql() {
        if (null == relationCode || relationCode.isEmpty()) {
            return fieldName;
        }
        return relationCode + "." + fieldName;
    }
}
